
TOPDIR := $(shell pwd)
TARGET_DIR = $(TOPDIR)/bin
#CFLAGS = -Os -Wall -pipe -mtune=mips32 -msoft-float -funit-at-a-time  -fpic -g
CFLAGS = 
CPPFLAGS = -I$(TOPDIR)/include  
CC = gcc

TARGET_CFLAGS =$(CFLAGS)
TARGET_CFLAGS +=$(CPPFLAGS)

export TOPDIR  TARGET_CFLAGS TARGET_DIR

obj-y += share

obj-y += debug
obj-y += cjson
obj-y += port_proxy 

obj-build := $(foreach obj,$(obj-y) $(obj-n),$(obj)-build)
obj-install := $(foreach obj,$(obj-y) $(obj-n),$(obj)-install)
obj-clean := $(foreach obj,$(obj-y) $(obj-n),$(obj)-clean)
includelist :=$(foreach obj,$(obj-y),rules/$(obj).mk)


include $(includelist)

target_build: $(obj-build)

target_install: $(obj-install)

target_clean: $(obj-clean)

all: target_build

install: target_install

clean: target_clean


